import $api from '.';

interface balance {
  name: string;
  number: number | string;
  [key: string]: any;
}

// 添加余额表
export const addbalance = function (data: balance) {
  return $api.post('/balance', data);
};

// 获取
export const getbalanceList = function () {
  // console.log('data', data);
  return $api.get('/balance', {
    // params: data,
  });
};

// 删除
export const delbalance = function (id: number) {
  return $api.delete(`/balance/${id}`);
};

// 修改余额
export const updatebalance = function (id: number, data: any) {
  return $api.patch(`/balance/${id}`, data);
};

export default {};
